package com.share.finance.risk.common.enums;

import com.share.common.utils.RandomUtil;
import lombok.Getter;

@Getter
public enum RepayPeriodsEnum {
    P3(3, "3期"), P6(6, "6期"), P9(9, "9期"), P12(12, "12期");

    //值
    public int value;

    //主题名字
    public String name;


    RepayPeriodsEnum(final int value, final String name) {
        this.value = value;
        this.name = name;
    }

    public static int randomValue() {
        RepayPeriodsEnum[] values = RepayPeriodsEnum.values();
        Integer random = RandomUtil.getRandom(values.length);
        return values[random].value;
    }
}
